package tech.aistar.corejava.day02;

/**
 * @author success
 * @version 1.0
 * @description:本类用来演示:
 * @date 2019/7/16 0016
 */
public class SwitchDemo {
    public static void main(String[] args) {
        int n = 10;

        switch (n){//byte short int char enum String
            case 3:
                System.out.println("3号");
                break;
            case 10:
                System.out.println("10...");
                //继续进入到下一个case
            case 9:
                System.out.println("9...");
                break;//跳出swich块...
            default:
                System.out.println("没有匹配到...");
        }

        System.out.println("===========");
        n = 100;
        switch (n){//byte short int char enum String
            case 3:
                System.out.println("3号");
                break;
            default:
                System.out.println("没有匹配到...");
                break;
            case 10:
                System.out.println("10...");
                //继续进入到下一个case
            case 9:
                System.out.println("9...");
                break;//跳出swich块..
        }

    }
}
